class AddRank < ActiveRecord::Migration
  def self.up
    add_column(:asin_infos,:title_rank,:integer)
    add_column(:asin_infos,:sales_rank,:integer)
    add_column(:asin_infos,:total_reviews_rank,:integer)
    add_column(:asin_infos,:average_rating_rank,:integer)
    add_column(:asin_infos,:price_rank,:integer)
    add_column(:asin_infos,:number_ofpages_rank,:integer)
    add_column(:asin_infos,:publication_date_rank,:integer)
  end

  def self.down
    remove_column(:asin_infos,:title_rank)
    remove_column(:asin_infos,:sales_rank)
    remove_column(:asin_infos,:total_reviews_rank)
    remove_column(:asin_infos,:average_rating_rank)
    remove_column(:asin_infos,:price_rank)
    remove_column(:asin_infos,:number_ofpages_rank)
    remove_column(:asin_infos,:publication_date_rank)
  end
end
